

<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<head>
  <meta charset="utf-8">
  
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  
  <title>describe.descriptors.soap &mdash; describe 0.1.0 documentation</title>
  

  
  
  
  

  

  
  
    

  

  <link rel="stylesheet" href="../../../_static/css/theme.css" type="text/css" />
  <link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
  <link rel="stylesheet" href="../../../_static/css/style.css" type="text/css" />
    <link rel="author" title="About these documents" href="../../../about.html" />
    <link rel="index" title="Index" href="../../../genindex.html" />
    <link rel="search" title="Search" href="../../../search.html" /> 

  
  <script src="../../../_static/js/modernizr.min.js"></script>

</head>

<body class="wy-body-for-nav">

   
  <div class="wy-grid-for-nav">

    
    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
      <div class="wy-side-scroll">
        <div class="wy-side-nav-search">
          

          
            <a href="../../../index.html" class="icon icon-home"> describe
          

          
          </a>

          
            
            
              <div class="version">
                0.1.0
              </div>
            
          

          
<div role="search">
  <form id="rtd-search-form" class="wy-form" action="../../../search.html" method="get">
    <input type="text" name="q" placeholder="Search docs" />
    <input type="hidden" name="check_keywords" value="yes" />
    <input type="hidden" name="area" value="default" />
  </form>
</div>

          
        </div>

        <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
          
            
            
              
            
            
              <ul>
<li class="toctree-l1"><a class="reference internal" href="../../../install.html">Installation</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../../tutorials/tutorials.html">Tutorials</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../../doc/modules.html">Documentation</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../../about.html">About</a></li>
</ul>

            
          
        </div>
      </div>
    </nav>

    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">

      
      <nav class="wy-nav-top" aria-label="top navigation">
        
          <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
          <a href="../../../index.html">describe</a>
        
      </nav>


      <div class="wy-nav-content">
        
        <div class="rst-content">
        
          















<div role="navigation" aria-label="breadcrumbs navigation">

  <ul class="wy-breadcrumbs">
    
      <li><a href="../../../index.html">Docs</a> &raquo;</li>
        
          <li><a href="../../index.html">Module code</a> &raquo;</li>
        
      <li>describe.descriptors.soap</li>
    
    
      <li class="wy-breadcrumbs-aside">
        
      </li>
    
  </ul>

  
  <hr/>
</div>
          <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
           <div itemprop="articleBody">
            
  <h1>Source code for describe.descriptors.soap</h1><div class="highlight"><pre>
<span></span><span class="kn">from</span> <span class="nn">__future__</span> <span class="k">import</span> <span class="n">absolute_import</span><span class="p">,</span> <span class="n">division</span><span class="p">,</span> <span class="n">print_function</span>
<span class="kn">from</span> <span class="nn">builtins</span> <span class="k">import</span> <span class="nb">super</span>
<span class="kn">import</span> <span class="nn">numpy</span> <span class="k">as</span> <span class="nn">np</span>

<span class="kn">from</span> <span class="nn">describe.descriptors</span> <span class="k">import</span> <span class="n">Descriptor</span>
<span class="kn">import</span> <span class="nn">soaplite</span>


<div class="viewcode-block" id="SOAP"><a class="viewcode-back" href="../../../doc/describe.descriptors.html#describe.descriptors.soap.SOAP">[docs]</a><span class="k">class</span> <span class="nc">SOAP</span><span class="p">(</span><span class="n">Descriptor</span><span class="p">):</span>
    <span class="sd">&quot;&quot;&quot;</span>
<span class="sd">    &quot;&quot;&quot;</span>
    <span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span>
            <span class="bp">self</span><span class="p">,</span>
            <span class="n">atomic_numbers</span><span class="p">,</span>
            <span class="n">rcut</span><span class="p">,</span>
            <span class="n">nmax</span><span class="p">,</span>
            <span class="n">lmax</span><span class="p">,</span>
            <span class="n">periodic</span><span class="p">,</span>
            <span class="n">envPos</span><span class="o">=</span><span class="kc">None</span><span class="p">,</span>
            <span class="n">crossover</span><span class="o">=</span><span class="kc">True</span><span class="p">,</span>
            <span class="n">all_atomtypes</span><span class="o">=</span><span class="p">[]</span>
            <span class="p">):</span>
        <span class="sd">&quot;&quot;&quot;</span>
<span class="sd">        &quot;&quot;&quot;</span>
        <span class="nb">super</span><span class="p">()</span><span class="o">.</span><span class="fm">__init__</span><span class="p">(</span><span class="n">flatten</span><span class="o">=</span><span class="kc">False</span><span class="p">)</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span> <span class="o">=</span> <span class="n">atomic_numbers</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">rcut</span> <span class="o">=</span> <span class="n">rcut</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">nmax</span> <span class="o">=</span> <span class="n">nmax</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">lmax</span> <span class="o">=</span> <span class="n">lmax</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">periodic</span> <span class="o">=</span> <span class="n">periodic</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">envPos</span> <span class="o">=</span> <span class="n">envPos</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span> <span class="o">=</span> <span class="n">crossover</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">myAlphas</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">myBetas</span> <span class="o">=</span> <span class="n">soaplite</span><span class="o">.</span><span class="n">genBasis</span><span class="o">.</span><span class="n">getBasisFunc</span><span class="p">(</span><span class="n">rcut</span><span class="p">,</span> <span class="n">nmax</span><span class="p">)</span>
        <span class="bp">self</span><span class="o">.</span><span class="n">all_atomtypes</span> <span class="o">=</span> <span class="n">all_atomtypes</span>

<div class="viewcode-block" id="SOAP.describe"><a class="viewcode-back" href="../../../doc/describe.descriptors.html#describe.descriptors.soap.SOAP.describe">[docs]</a>    <span class="k">def</span> <span class="nf">describe</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">system</span><span class="p">):</span>
        <span class="sd">&quot;&quot;&quot;Return the SOAP spectrum for the given system.</span>

<span class="sd">        Args:</span>
<span class="sd">            system (System): The system for which the descriptor is created.</span>

<span class="sd">        Returns:</span>
<span class="sd">            np.ndarray: The SOAP spectrum for the given system.</span>
<span class="sd">        &quot;&quot;&quot;</span>
        <span class="n">rcut</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">rcut</span>
        <span class="n">nmax</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">nmax</span>
        <span class="n">lmax</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">lmax</span>
        <span class="n">periodic</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">periodic</span>
        <span class="n">envPos</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">envPos</span>
        <span class="n">crossover</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span>
        <span class="n">myAlphas</span><span class="p">,</span> <span class="n">myBetas</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">myAlphas</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">myBetas</span>
        <span class="n">all_atomtypes</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">all_atomtypes</span>
        <span class="k">if</span> <span class="n">envPos</span> <span class="ow">is</span> <span class="kc">None</span><span class="p">:</span>
            <span class="k">if</span> <span class="n">periodic</span> <span class="ow">is</span> <span class="kc">False</span><span class="p">:</span>
                <span class="n">soap_mat</span> <span class="o">=</span> <span class="n">soaplite</span><span class="o">.</span><span class="n">get_soap_structure</span><span class="p">(</span><span class="n">system</span><span class="p">,</span> <span class="n">myAlphas</span><span class="p">,</span> <span class="n">myBetas</span><span class="p">,</span> <span class="n">rCut</span><span class="o">=</span><span class="n">rcut</span><span class="p">,</span> <span class="n">NradBas</span><span class="o">=</span><span class="n">nmax</span><span class="p">,</span> <span class="n">Lmax</span><span class="o">=</span><span class="n">lmax</span><span class="p">,</span> <span class="n">crossOver</span><span class="o">=</span><span class="n">crossover</span><span class="p">,</span> <span class="n">all_atomtypes</span><span class="o">=</span><span class="n">all_atomtypes</span><span class="p">)</span>  <span class="c1"># OKAY</span>
            <span class="k">else</span><span class="p">:</span>
                <span class="n">soap_mat</span> <span class="o">=</span> <span class="n">soaplite</span><span class="o">.</span><span class="n">get_periodic_soap_structure</span><span class="p">(</span><span class="n">system</span><span class="p">,</span> <span class="n">myAlphas</span><span class="p">,</span> <span class="n">myBetas</span><span class="p">,</span> <span class="n">rCut</span><span class="o">=</span><span class="n">rcut</span><span class="p">,</span> <span class="n">NradBas</span><span class="o">=</span><span class="n">nmax</span><span class="p">,</span> <span class="n">Lmax</span><span class="o">=</span><span class="n">lmax</span><span class="p">,</span> <span class="n">crossOver</span><span class="o">=</span><span class="n">crossover</span><span class="p">,</span> <span class="n">all_atomtypes</span><span class="o">=</span><span class="n">all_atomtypes</span><span class="p">)</span>  <span class="c1"># OKAY</span>
        <span class="k">elif</span> <span class="nb">isinstance</span><span class="p">(</span><span class="n">envPos</span><span class="p">,</span> <span class="nb">int</span><span class="p">):</span>  <span class="c1"># gives index of atom (from zero)</span>
            <span class="k">if</span> <span class="n">periodic</span> <span class="ow">is</span> <span class="kc">False</span><span class="p">:</span>
                <span class="n">soap_mat</span> <span class="o">=</span> <span class="n">soaplite</span><span class="o">.</span><span class="n">get_soap_locals</span><span class="p">(</span><span class="n">system</span><span class="p">,</span> <span class="p">[</span><span class="n">system</span><span class="o">.</span><span class="n">get_positions</span><span class="p">()[</span><span class="n">envPos</span><span class="p">]],</span> <span class="n">myAlphas</span><span class="p">,</span> <span class="n">myBetas</span><span class="p">,</span> <span class="n">rCut</span><span class="o">=</span><span class="n">rcut</span><span class="p">,</span> <span class="n">NradBas</span><span class="o">=</span><span class="n">nmax</span><span class="p">,</span> <span class="n">Lmax</span><span class="o">=</span><span class="n">lmax</span><span class="p">,</span> <span class="n">crossOver</span><span class="o">=</span><span class="n">crossover</span><span class="p">,</span> <span class="n">all_atomtypes</span><span class="o">=</span><span class="n">all_atomtypes</span><span class="p">)</span>
            <span class="k">else</span><span class="p">:</span>
                <span class="n">soap_mat</span> <span class="o">=</span> <span class="n">soaplite</span><span class="o">.</span><span class="n">get_periodic_soap_locals</span><span class="p">(</span><span class="n">system</span><span class="p">,</span> <span class="p">[</span><span class="n">system</span><span class="o">.</span><span class="n">get_positions</span><span class="p">()[</span><span class="n">envPos</span><span class="p">]],</span> <span class="n">myAlphas</span><span class="p">,</span> <span class="n">myBetas</span><span class="p">,</span> <span class="n">rCut</span><span class="o">=</span><span class="n">rcut</span><span class="p">,</span> <span class="n">NradBas</span><span class="o">=</span><span class="n">nmax</span><span class="p">,</span> <span class="n">Lmax</span><span class="o">=</span><span class="n">lmax</span><span class="p">,</span> <span class="n">crossOver</span><span class="o">=</span><span class="n">crossover</span><span class="p">,</span> <span class="n">all_atomtypes</span><span class="o">=</span><span class="n">all_atomtypes</span><span class="p">)</span>
        <span class="k">else</span><span class="p">:</span>
            <span class="k">if</span> <span class="n">periodic</span> <span class="ow">is</span> <span class="kc">False</span><span class="p">:</span>
                <span class="n">soap_mat</span> <span class="o">=</span> <span class="n">soaplite</span><span class="o">.</span><span class="n">get_soap_locals</span><span class="p">(</span><span class="n">system</span><span class="p">,</span> <span class="n">envPos</span><span class="p">,</span> <span class="n">myAlphas</span><span class="p">,</span> <span class="n">myBetas</span><span class="p">,</span> <span class="n">rCut</span><span class="o">=</span><span class="n">rcut</span><span class="p">,</span> <span class="n">NradBas</span><span class="o">=</span><span class="n">nmax</span><span class="p">,</span> <span class="n">Lmax</span><span class="o">=</span><span class="n">lmax</span><span class="p">,</span> <span class="n">crossOver</span><span class="o">=</span><span class="n">crossover</span><span class="p">,</span> <span class="n">all_atomtypes</span><span class="o">=</span><span class="n">all_atomtypes</span><span class="p">)</span>  <span class="c1"># OKAY</span>
            <span class="k">else</span><span class="p">:</span>
                <span class="n">soap_mat</span> <span class="o">=</span> <span class="n">soaplite</span><span class="o">.</span><span class="n">get_periodic_soap_locals</span><span class="p">(</span><span class="n">system</span><span class="p">,</span> <span class="n">envPos</span><span class="p">,</span> <span class="n">myAlphas</span><span class="p">,</span> <span class="n">myBetas</span><span class="p">,</span> <span class="n">rCut</span><span class="o">=</span><span class="n">rcut</span><span class="p">,</span> <span class="n">NradBas</span><span class="o">=</span><span class="n">nmax</span><span class="p">,</span> <span class="n">Lmax</span><span class="o">=</span><span class="n">lmax</span><span class="p">,</span> <span class="n">crossOver</span><span class="o">=</span><span class="n">crossover</span><span class="p">,</span> <span class="n">all_atomtypes</span><span class="o">=</span><span class="n">all_atomtypes</span><span class="p">)</span>  <span class="c1"># OKAY</span>

        <span class="k">return</span> <span class="n">soap_mat</span></div>

<div class="viewcode-block" id="SOAP.get_number_of_features"><a class="viewcode-back" href="../../../doc/describe.descriptors.html#describe.descriptors.soap.SOAP.get_number_of_features">[docs]</a>    <span class="k">def</span> <span class="nf">get_number_of_features</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
        <span class="sd">&quot;&quot;&quot;Used to inquire the final number of features that this descriptor</span>
<span class="sd">        will have.</span>

<span class="sd">        Returns:</span>
<span class="sd">            int: Number of features for this descriptor.</span>
<span class="sd">        &quot;&quot;&quot;</span>
        <span class="k">return</span> <span class="n">np</span><span class="o">.</span><span class="n">prod</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">get_shape</span><span class="p">())</span></div>

<div class="viewcode-block" id="SOAP.get_shape"><a class="viewcode-back" href="../../../doc/describe.descriptors.html#describe.descriptors.soap.SOAP.get_shape">[docs]</a>    <span class="k">def</span> <span class="nf">get_shape</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
        <span class="sd">&quot;&quot;&quot;Used to inquire the final number of features that this descriptor</span>
<span class="sd">        will have.</span>

<span class="sd">        Returns:</span>
<span class="sd">            int: Number of features for this descriptor.</span>
<span class="sd">        &quot;&quot;&quot;</span>
        <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">envPos</span> <span class="ow">is</span> <span class="kc">None</span><span class="p">:</span>
            <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span> <span class="ow">is</span> <span class="kc">False</span><span class="p">:</span>
                <span class="k">return</span> <span class="n">np</span><span class="o">.</span><span class="n">array</span><span class="p">([(</span><span class="bp">self</span><span class="o">.</span><span class="n">lmax</span><span class="o">+</span><span class="mi">1</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">+</span><span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="o">*</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">),</span> <span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)])</span>
            <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span> <span class="ow">is</span> <span class="kc">True</span><span class="p">:</span>
                <span class="k">return</span> <span class="n">np</span><span class="o">.</span><span class="n">array</span><span class="p">([(</span><span class="bp">self</span><span class="o">.</span><span class="n">lmax</span><span class="o">+</span><span class="mi">1</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">+</span><span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="o">*</span><span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)</span> <span class="o">+</span> <span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="p">,</span> <span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)])</span>
        <span class="k">elif</span> <span class="nb">isinstance</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">envPos</span><span class="p">,</span> <span class="nb">int</span><span class="p">):</span>  <span class="c1"># gives index of atom (from zero)</span>
            <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span> <span class="ow">is</span> <span class="kc">False</span><span class="p">:</span>
                <span class="k">return</span> <span class="n">np</span><span class="o">.</span><span class="n">array</span><span class="p">([(</span><span class="bp">self</span><span class="o">.</span><span class="n">lmax</span><span class="o">+</span><span class="mi">1</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">+</span><span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="o">*</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">),</span> <span class="mi">1</span><span class="p">])</span>
            <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span> <span class="ow">is</span> <span class="kc">True</span><span class="p">:</span>
                <span class="k">return</span> <span class="n">np</span><span class="o">.</span><span class="n">array</span><span class="p">([(</span><span class="bp">self</span><span class="o">.</span><span class="n">lmax</span><span class="o">+</span><span class="mi">1</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">+</span><span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="o">*</span><span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)</span> <span class="o">+</span> <span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="p">,</span> <span class="mi">1</span><span class="p">])</span>
        <span class="k">else</span><span class="p">:</span>
            <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span> <span class="ow">is</span> <span class="kc">False</span><span class="p">:</span>
                <span class="k">return</span> <span class="n">np</span><span class="o">.</span><span class="n">array</span><span class="p">([(</span><span class="bp">self</span><span class="o">.</span><span class="n">lmax</span><span class="o">+</span><span class="mi">1</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">+</span><span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="o">*</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">),</span> <span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">envPos</span><span class="p">)])</span>
            <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">crossover</span> <span class="ow">is</span> <span class="kc">True</span><span class="p">:</span>
                <span class="k">return</span> <span class="n">np</span><span class="o">.</span><span class="n">array</span><span class="p">([(</span><span class="bp">self</span><span class="o">.</span><span class="n">lmax</span><span class="o">+</span><span class="mi">1</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">*</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">nmax</span><span class="o">+</span><span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="o">*</span><span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)</span><span class="o">*</span><span class="p">(</span><span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">atomic_numbers</span><span class="p">)</span> <span class="o">+</span> <span class="mi">1</span><span class="p">))</span><span class="o">/</span><span class="mi">2</span><span class="p">,</span> <span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">envPos</span><span class="p">)])</span></div></div>
</pre></div>

           </div>
           
          </div>
          <footer>
  

  <hr/>

  <div role="contentinfo">
    <p>
        &copy; Copyright .

    </p>
  </div>
  Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>. 

</footer>

        </div>
      </div>

    </section>

  </div>
  


  

    <script type="text/javascript">
        var DOCUMENTATION_OPTIONS = {
            URL_ROOT:'../../../',
            VERSION:'0.1.0',
            LANGUAGE:'None',
            COLLAPSE_INDEX:false,
            FILE_SUFFIX:'.html',
            HAS_SOURCE:  true,
            SOURCELINK_SUFFIX: '.txt'
        };
    </script>
      <script type="text/javascript" src="../../../_static/jquery.js"></script>
      <script type="text/javascript" src="../../../_static/underscore.js"></script>
      <script type="text/javascript" src="../../../_static/doctools.js"></script>
      <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>

  

  <script type="text/javascript" src="../../../_static/js/theme.js"></script>

  <script type="text/javascript">
      jQuery(function () {
          SphinxRtdTheme.Navigation.enable(true);
      });
  </script> 

</body>
</html>